<template>
  <view>
    <view class="list">
      <view class="item" v-for="item in fieldInfoList" :key="item.fl_userid">
        <view class="flex-row justify-between info align-center">
          <view class="flex-row align-center">
            <!-- <image :src="item.thumb_avatar" mode="" /> -->
            <text>{{ item.name }}</text>
          </view>
          <text>{{ item.fl_createtime }}</text>
        </view>
        <view class="statistics">
          <view v-if="item.follow_createtime"
            >近期跟进：{{ item.follow_createtime }}</view
          >
          <view v-if="item.follow_nums">累计跟进{{ item.follow_nums }}次</view>
        </view>
      </view>
    </view>
  </view>
</template>
<script>
import { getWorkerAll } from '@/config/api'
export default {
  data() {
    return {
      getWorkerAllList: [],
      fieldInfoList: [],
      userid: uni.getStorageSync('clientId'),
    }
  },
  onLoad() {
    this.getWorkerAllData()
  },
  methods: {
    async getWorkerAllData() {
      const res = await getWorkerAll({
        userid: this.userid,
      })
      this.fieldInfoList = res.data
    },
  },
}
</script>
<style lang="scss" >
.list {
  .item {
    background: #fff;
    border-radius: 8rpx;
    padding: 16rpx 28rpx;
    margin: 16rpx 28rpx;

    .info {
      width: 100%;
    }
    image {
      width: 72rpx;
      height: 72rpx;
      border-radius: 4rpx;
      margin-right: 28rpx;
    }
    .statistics {
      text-align: right;
      color: #9999a5;
    }
  }
}
</style>
